<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<html><head><title>PyGUI - class Font</title>
  
                                   <meta name="GENERATOR" content="Mozilla/3.01Gold (X11; I; SunOS 5.6 sun4u) [Netscape]"></head>
<body>
       <h1>class <tt>Font</tt> </h1>
       <p>A Font object represents a set of characters of a particular typeface, 
  style and size. Font objects are immutable. </p>
       <h2>Constructor </h2>
       <dl>
  <dl>
    <dt><tt>Font(family</tt><tt>, size</tt><tt>, style) </tt></dt>
    <dd>The family is the name of a font family ("Times", "Helvetica", etc...). 
 The size is measured in points.
  The style is a list of zero or more of: <tt>'bold'</tt>, <tt>'italic'</tt>. </dd>
  </dl>
</dl>
       <h2>Properties </h2>
       <dl>
  <dl>
    <dt><tt>family</tt></dt>
    <dd><i>Read-only.</i> Family name of the font.</dd>
    <dd><tt><br>
         </tt></dd>
    <dt><tt>style</tt></dt>
    <dd><i>Read-only.</i> Style of the font.</dd>
    <dd><br>
       </dd>
    <dt><tt>size</tt></dt>
    <dd><i>Read-only.</i> Point size of the font.</dd>
    <dd><br>
       </dd>
    <dt><tt>ascent</tt></dt>
    <dd><i>Read-only.</i> Distance from the baseline of the font to the top 
 of the tallest character.</dd>
    <dd><br>
       </dd>
    <dt><tt>descent </tt></dt>
    <dd><i>Read-only.</i> Distance from the baseline of the font to the bottom 
 of the lowest character.</dd>
    <dd><br>
       </dd>
    <dt><tt>height</tt></dt>
    <dd><i>Read-only.</i> Height of the font (equal to ascent + 
 descent).<br><br>
      </dd><dt style="font-family: monospace;">leading</dt><dd><span style="font-style: italic;">Read-only.</span> Recommended space to leave between adjacent lines of text.<br><br></dd><dt style="font-family: monospace;">line_height</dt>
    <dd><span style="font-style: italic;">Read-only.</span> Recommended distance between the baselines of adjacent lines of text (equal to ascent + descent + leading).<br><br></dd><dt style="font-family: monospace;">cap_height</dt><dd><span style="font-style: italic;">Read-only. </span>Height above the baseline of capital letters. May not be accurate on all platforms.<br><br></dd><dt style="font-family: monospace;">x_height</dt><dd><span style="font-style: italic;">Read-only. </span>Height above the baseline of lower case letters without ascenders. May not be accurate on all platforms.</dd>

  </dl>
</dl>
   <h2>&nbsp;Methods</h2>
   <dl>
  <dl>
    <dt><tt>width(string [,start [,end]]) </tt></dt>
    <dd>Returns the width of the specified part of the given string when
drawn in this font.       </dd>
  </dl>
</dl>
      <h2>Constants</h2>
   <dl>
  <dt><tt>system_font</tt></dt>
  <dt><tt>application_font</tt></dt>
  <dd>Predefined Font instances representing the standard fonts for system 
 text and application text, respectively.</dd>
</dl>
   <br>
    <br>
  <br>
 <br>
</body></html>